package com.github.wendao76.skill.exception;

/**
 * 类描述信息
 *
 * @author wendao76
 * @version 1.0
 * @since 2022-3-6
 */
public class BaseException extends Throwable {
  private Integer code;
  private Object[] params;

  public BaseException(IExceptionEnum<Integer> exceptionEnum, Object[] objs, String message) {
    super(message);
    this.params = objs;
    this.code = exceptionEnum.getCode();
  }

  public BaseException(
      IExceptionEnum<Integer> exceptionEnum, Object[] objs, String message, Throwable throwable) {
    super(message, throwable);
    this.params = objs;
    this.code = exceptionEnum.getCode();
  }
}
